//
// Decompiled by Jadx - 374ms
//
package me.plusne.GreenDao.dao;

import android.database.Cursor;
import android.database.sqlite.SQLiteStatement;
import androidx.activity.b;
import fm.j;
import org.greenrobot.greendao.database.DatabaseStatement;
import x.a;
import x.d;

public final class SoulAutoLogDao extends a<j, Long> {
    public static final String TABLENAME = "SOUL_AUTO_LOG";

    public class Properties {
        public static final d Id = new d(0, Long.class, "id", true, "_id");
        public static final d PostId = new d(1, Long.TYPE, "postId", false, "POST_ID");
        public static final d Type = new d(2, Integer.TYPE, "type", false, "TYPE");
    }
    public SoulAutoLogDao(g.a aVar) {
        super(aVar);
    }

    public static void createTable(org.greenrobot.greendao.database.Database aVar, boolean z) {
        String str;
        if (z) {
            str = "IF NOT EXISTS ";
        } else {
            str = "";
        }
        aVar.d("CREATE TABLE " + str + "\"SOUL_AUTO_LOG\" (\"_id\" INTEGER PRIMARY KEY AUTOINCREMENT ,\"POST_ID\" INTEGER NOT NULL ,\"TYPE\" INTEGER NOT NULL );");
        aVar.d("CREATE INDEX " + str + "IDX_SOUL_AUTO_LOG_POST_ID ON \"SOUL_AUTO_LOG\" (\"POST_ID\" ASC);");
        b.v(new StringBuilder("CREATE INDEX "), str, "IDX_SOUL_AUTO_LOG_TYPE ON \"SOUL_AUTO_LOG\" (\"TYPE\" ASC);", aVar);
    }

    public static void dropTable(org.greenrobot.greendao.database.Database aVar, boolean z) {
        String str;
        StringBuilder sb = new StringBuilder("DROP TABLE ");
        if (z) {
            str = "IF EXISTS ";
        } else {
            str = "";
        }
        b.v(sb, str, "\"SOUL_AUTO_LOG\"", aVar);
    }

    public final void a(SQLiteStatement sQLiteStatement, Object obj) {
        j jVar = (j) obj;
        sQLiteStatement.clearBindings();
        Long l = jVar.a;
        if (l != null) {
            sQLiteStatement.bindLong(1, l.longValue());
        }
        sQLiteStatement.bindLong(2, jVar.b);
        sQLiteStatement.bindLong(3, jVar.c);
    }

    public final void b(Object obj, DatabaseStatement cVar) {
        j jVar = (j) obj;
        cVar.k();
        Long l = jVar.a;
        if (l != null) {
            cVar.j(1, l.longValue());
        }
        cVar.j(2, jVar.b);
        cVar.j(3, jVar.c);
    }

    public final Long c(Object obj) {
        j jVar = (j) obj;
        if (jVar != null) {
            return jVar.a;
        }
        return null;
    }

    public final Object d(Cursor cursor) {
        return new j(cursor.isNull(0) ? null : Long.valueOf(cursor.getLong(0)), cursor.getLong(1), cursor.getInt(2));
    }

    public final Long e(Cursor cursor) {
        if (cursor.isNull(0)) {
            return null;
        }
        return Long.valueOf(cursor.getLong(0));
    }

    public final Long f(long j, Object obj) {
        ((j) obj).a = Long.valueOf(j);
        return Long.valueOf(j);
    }
}
